package cn.jsu.oj.judgment.config;


import cn.jsu.oj.judgment.factory.JudgeFactory;
import cn.jsu.oj.judgment.factory.JudgeStartFactory;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.DependsOn;

/**
 * 判题机工厂配置
 *
 */

@Configuration("judgeFactoryConfig")
@DependsOn({"springContext","judgeExecutor"})
public class JudgeFactoryConfig {


    @Bean("judgeStarterFactory")
    JudgeFactory initSubjectStarterFactory() {
        JudgeFactory judgeStarterFactory = new JudgeStartFactory();
        judgeStarterFactory.build();
        return judgeStarterFactory;
    }
}
